#!/bin/bash

#creo dei link di ogni header file nei source folder in "include"

SOURCEFILES="../lexical ../main ../src ../symboltable ../syntax"
TARGETDIRECTORY="../include"
HEADERFILES=""

for headerfolder in ${SOURCEFILES}
do
	HEADERFILES=`ls -l ${headerfolder} | tr -s "  " | cut -d" " -f8 | grep -e '\.h$'`
	for headerfile in ${HEADERFILES}
	do
		ln -s -f -T ${headerfolder}/${headerfile} ${TARGETDIRECTORY}/${headerfile}
	done
done